<template>
  <view>
    <y-tabs v-model="active" sticky :offsetTop="43" color="#007aff">
      <y-tab v-for="item in tabsList" :key="item.value" :title="item.title"></y-tab>
    </y-tabs>

    <BoxList v-if="active === 0" />
    <ConvergeList v-if="active === 1" />
  </view>
</template>

<script setup>
  import BoxList from './components/box-list.vue';
  import ConvergeList from './components/converge-list.vue';

  import { ref } from 'vue';

  const active = ref(0);

  const tabsList = [
    {
      title: '盒子',
      value: 0,
    },
    {
      title: '汇聚',
      value: 1,
    },
  ];
</script>

<style lang="scss" scoped>
  page {
    background-color: #f5f5f5;
  }
</style>
